package com.iplay.headfirst.chapter1;

/**
 * 绿头鸭
 * @author dangwu
 * @since 2021/3/10 12:56 下午
 */
public class MallardDuck extends  BaseDuck{

    public MallardDuck() {
        setQuackBehavior(new Quack());
        setFlyBehavior(new FlyWithWings());
    }

    @Override
    public void display() {
        System.out.println("========绿头=======");
    }
}
